package com.example.controller;

import com.example.util.ResultUtil;
import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class DemoController {

    @RequiresPermissions("user:add")
    @GetMapping("/user/add")
    public Object addUser() {
        return ResultUtil.success("新增用户成功", null);
    }

    @RequiresPermissions("video:add")
    @GetMapping("/vide/add")
    public Object addVideo() {
        return ResultUtil.success("新增视频成功", null);
    }
}
